<template>
  <div class="swiper-container kerwin">
      <div class="swiper-wrapper">
        <slot></slot>
      </div>
		<div class="swiper-pagination"></div>
  </div>
</template>

<script>
import Swiper from 'swiper/bundle';
import 'swiper/css/bundle';
export default {
  props: {
    loop: {
      type: Boolean,
      default: true
    }
  },
  mounted() {
      new Swiper(".kerwin", {
       // direction: "vertical", // 垂直切换选项
        // 如果需要分页器
      pagination: {
          el: ".swiper-pagination",
            },
            loop: this.loop, // 循环模式选项
            autoplay: {
					delay: 2500,
					disableOnInteraction: false,
            },
    });
  },
}
</script>
